<%@ page language="java" contentType="text/html; charset=ISO-8859-1"
    pageEncoding="ISO-8859-1"%>
    <%@ taglib prefix="sec" uri="http://www.springframework.org/security/tags" %>
<!DOCTYPE html PUBLIC "-//W3C//DTD HTML 4.01 Transitional//EN" "http://www.w3.org/TR/html4/loose.dtd">
					
<html lang="en">
    <head>
        <title>NMCEX</title>
        <meta charset="UTF-8" />
        <meta http-equiv="X-UA-Compatible" content="IE=edge,chrome=1"> 
        <meta name="viewport" content="width=device-width, initial-scale=1.0"> 
        <meta name="description" content="Animated Buttons with CSS3" />
        <meta name="keywords" content="css3, transitions, button, animation, hover, effect, icon, call-to-action, active" />
        <meta name="author" content="Codrops" />
        <meta http-equiv="Content-Type" content="text/html; charset=UTF-8">	
		<meta name="keywords" content="jquery,ui,easy,easyui,web">
		<meta name="description" content="easyui help you build your web page easily!">
		<link rel="stylesheet" type="text/css" href="http://www.jeasyui.com/easyui/themes/default/easyui.css">
		<link rel="stylesheet" type="text/css" href="http://www.jeasyui.com/easyui/themes/icon.css">
		<script type="text/javascript" src="http://code.jquery.com/jquery-1.6.1.min.js"></script>
		<script type="text/javascript" src="http://www.jeasyui.com/easyui/jquery.easyui.min.js"></script>
        <link rel="shortcut icon" href="../favicon.ico"> 
        <link rel="stylesheet" type="text/css" href="css/demo.css" />
        <link rel="stylesheet" type="text/css" href="css/style5.css" />
        <link href='http://fonts.googleapis.com/css?family=Oswald' rel='stylesheet' type='text/css' />
		<script type="text/javascript" src="js/shortcuts.js" language="javascript"></script>
		<script src="http://cdn.sockjs.org/sockjs-0.3.min.js"></script>
		<script src="js/stomp.js"></script>
		
<style type="text/css">
			  tbody tr:hover td { background-color: #000; color :#FFF}
			 
@charset "UTF-8";

#blanketA,#blanketA2 {
background-color:#666666;
   opacity: 0.65;
   *background:none;
   position:absolute;
   z-index: 9001;
   top:0px;
   left:0px;
   width:100%;
   height:100%;
}
#popUpDivA,#popUpDivA2 {
	position:fixed;

	
	border-radius:20px;
	width:auto%;
	margin-left:30%;
	margin-right:30%;
	padding-bottom:0%;
	height:auto;

	z-index: 9002;
	top:120px;
	text-align:center;
	min-height:inherit;
	max-height:inherit;
}
.overlay {    
    bottom: 0;
    cursor: default;
    left: 0;
    opacity: 0;
    position:relative;
    right: 0;
    top: 0;
    z-index: 1;

    -webkit-transition: opacity .5s;
    -moz-transition: opacity .5s;
    -ms-transition: opacity .5s;
    -o-transition: opacity .5s;
    transition: opacity .5s;
}
.overlay:target {
    visibility: visible;
    opacity: 1;
}
.close {
    background-color: rgba(0, 0, 0, 0.8);
    height: 30px;
    line-height: 30px;
    position: absolute;
    right: -5px;
    text-align: center;
    text-decoration: none;
    top: -6px;
    width: 30px;

    -webkit-border-radius: 15px;
    -moz-border-radius: 15px;
    -ms-border-radius: 15px;
    -o-border-radius: 15px;
    border-radius: 15px;
}
.close:before {
    color: rgba(255, 255, 255, 0.9);
    content: "X";
    font-size: 24px;
    text-shadow: 0 -1px rgba(0, 0, 0, 0.9);
}
.close:hover {
    background-color: rgba(64, 128, 128, 0.8);
}
</style>
			<script type="text/javascript">
		var x;

function changecolors() {
    x = 1;
    setInterval(change, 1000);
}

function change() {
	var m=0;
	var n=0;
	var profitloss=0;
	 $.get('./countProfitLoss',function(responseJson) {
	 for(var a in responseJson){
		 m=m+(Number(responseJson[a]["lot1"])*Number(responseJson[a]["price1"]));
		 n=n+(Number(responseJson[a]["lot1"])*Number(responseJson[a]["price2"]));
		 profitloss=m-n;
	 }
	
	 if(profitloss>0){
		 document.getElementById('profit').style.background = "green";;
		 document.getElementById("profit").value="Profit: "+profitloss;
		 
	 }
	 else{
		 document.getElementById('profit').style.background = "red";;
		 document.getElementById("profit").value="Loss: "+profitloss;
		 	 
	 }
	 
	 });
  
    
}


function textsizer(e){

var evtobj=window.event? event : e; 
var unicode=evtobj.charCode? evtobj.charCode : evtobj.keyCode;
var actualkey=String.fromCharCode(unicode);
 if (actualkey=="f1"){
if(document.getElementById('blanketA2').style.display == "block"){
document.getElementById('blanketA2').style.display = "none";
document.getElementById('popUpDivA2').style.display = "none";
}
document.getElementById('blanketA').style.display = "block";
document.getElementById('popUpDivA').style.display = "block";

}
if (actualkey=="f2"){
if(document.getElementById('blanketA').style.display == "block"){
document.getElementById('blanketA').style.display = "none";
document.getElementById('popUpDivA').style.display = "none";
}
document.getElementById('blanketA2').style.display = "block";
document.getElementById('popUpDivA2').style.display = "block";
}
}
document.onkeypress=textsizer;

function BuySell1(parameter){

if(parameter=='buy'){
document.getElementById('blanketA').style.display = "block";
document.getElementById('popUpDivA').style.display = "block";
}
if(parameter=='sell'){
document.getElementById('blanketA2').style.display = "block";
document.getElementById('popUpDivA2').style.display = "block";
}
}

function Close(){
	document.getElementById("popUpDivA").style.display = 'none';
	document.getElementById("blanketA").style.display = 'none';
	document.getElementById("popUpDivA2").style.display = 'none';
	document.getElementById("blanketA2").style.display = 'none';
}

$(document).ready(function(){
	$('#pwd1').live("paste",function(e) {
		 e.preventDefault();

	 });

	 $('#pwd').live("cut copy paste",function(e) {
		 e.preventDefault();

		});
	 
	 $('#tpwd1').live("paste",function(e) {
		 e.preventDefault();

	 });

	 $('#tpwd').live("cut copy paste",function(e) {
		 e.preventDefault();

		});
  $("#pass").blur(function(){
	 var pass= $("#pass").val(); 
	$.ajax({
		url : './mock/clientpage',
		dataType: "json",
		contentType: 'application/json',			  
		success : function(jsonData) {
			for(var a in jsonData){
				if(jsonData[a]["password"]!=pass){
					alert("You have Entered an incorrect Password.");
				}
			}
		}
	});
  });
  
  $("#tpass").blur(function(){
		 var pass= $("#tpass").val(); 
		
	    $.ajax({
			url : './mock/clientpage',
			dataType: "json",
			contentType: 'application/json',			  
			success : function(jsonData) {
				alert(jsonData);
				for(var a in jsonData){
				
					if(jsonData[a]["transpwd"]!=pass){
						alert("You have Entered an incorrect Password.");
					}
					
				}
			}
		});
	  });
  
	$("#submit1").click(function(event) { 
		var reqUrl="./user/UpdatePwd";
		var p1=$("#pwd").val();  
		var p2=$("#pwd1").val();  
		if(p1==p2){
		var jsondata = JSON.stringify({ "password":$("#pwd").val()});
		
	$.ajax(
		  {
		  type: "POST",
		  url: reqUrl,
		  dataType: "json",
		  contentType: 'application/json',	  
		  data:jsondata, 
		  success: function(html) { 
		    alert(html);
		  }
		  
		});
		}else{
			alert("Password field does not matches with Confirm Password.");
		}
	});
	
	$("#submit2").click(function(event) { 
		var reqUrl="./user/UpdateTransPwd";
		var p1=$("#tpwd").val();  
		var p2=$("#tpwd1").val();  
		if(p1==p2){
		var jsondata = JSON.stringify({ "transpwd":$("#tpwd").val()});
	$.ajax(
		  {
		  type: "POST",
		  url: reqUrl,
		  dataType: "json",
		  contentType: 'application/json',	  
		  data:jsondata, 
		  success: function(html) { 
		    alert(html);
		  }
		  
		});
		}else{
			alert("Password field does not matches with Confirm Password.");
		}
	});
});

</script>	
 
<script type="text/javascript">	
		$(function(){			
			$('#show').bind('contextmenu',function(e)
			{
				$('#mm').menu('show', 
				{
				left: e.pageX,			
				top: e.pageY
					});	
				return false;		
				});
			});	
			function showmenu(){	
			$('#mm').menu('show', {
			left: 90,
			top: 170,
			});

			}

	</script>
<script type="text/javascript">	
		$(function(){			
			$('#show1').bind('contextmenu',function(e)
			{
				$('#ks').menu('show', 
				{
				left: e.pageX,			
				top: e.pageY
					});	
				return false;		
				});
			});	
			function showmenu(){	
			$('#ks').menu('show', {
			left: 340,
			top: 60,
			});

			}

	</script>
		
    </head>
    <body onLoad="changecolors();">
     
	<div id="blanketA" class="overlay" style="display:none;"></div>
		<div id="popUpDivA" style="display:none; width:582px; left:-52px; top:131px; cursor:pointer; font-family: Helvetica, sans-serif; ">
			<div style="color:#000;">
         		
                <div id="login">
				<h2><span class="fontawesome-lock"></span>Change Password</h2>
				  
		<form name="form1" id="orderForm" method="post" action="./buy">
		<fieldset>
		                 <p><label for="nstr. Name" style="margin-left:70px;">Old Password</label>
				<input type="password"   size="55" name="pass" id="pass" style="margin-left:55px;"></input></p>
               <p> <label for="TotalQty" class="label-margin" style="margin-left:70px;">New Password</label>
                <input type="password"   size="55"  name="pwd" id="pwd" style="margin-left:50px;"></input></p>
              <p>  <label for="TotalQty" class="label-margin" style="margin-left:70px;">Confirm Password</label>
                <input type="password"   name="pwd1" id="pwd1"  size="55" style="margin-left:30px;"/></p>
          
               
   				<input type="button" id="submit1" value="Save" onclick="Close();"/>
			</fieldset>
		</form>
	</div>  
            </div>
     <a class="close" href="#close" onclick="Close();"></a>
	</div>
   <div id="blanketA2" class="overlay" style="display:none;"></div>
		<div id="popUpDivA2" style="display:none; width:582px; left:131px; left:-106px; cursor:pointer; font-family: Helvetica, sans-serif; ">
			<div style="color:#000;">
         		
                <div id="login">
				<h2><span class="fontawesome-lock"></span>Change Transaction Password</h2>
	
				<form name="form2" id="orderForm" method="post" action="./sell">
		<fieldset>
		   <p><label for="nstr. Name" style="margin-left:70px;">Old Password</label>
				<input type="password"  size="55" name="tpass" id="tpass" style="margin-left:55px;"></input></p>
               <p> <label for="TotalQty" class="label-margin" style="margin-left:70px;">New Password</label>
                <input type="password"  size="55" name="tpwd" id="tpwd" style="margin-left:50px;"></input></p>
              <p>  <label for="TotalQty" class="label-margin" style="margin-left:70px;">Confirm Password</label>
               <input type="password"   name="tpwd1" id="tpwd1"  size="55" style="margin-left:30px;"/></p>
   				<input type="button" id="submit2" value="Save" onclick="Close();"/>
			</fieldset>
		</form>	</div>  
            </div>
     <a class="close" href="#close" onclick="Close();"></a>
	</div>	 
       
        <div class="container">
            <div class="header">
               
                <div class="top-header">
                <nav>
            <ul class="fancyNav">
                <li id="home"><a href="index"><span class="a-btn-symbol"><img src="images/home-icon.png" style="width:27px; height:27px;"></span>Home</a></li>
                <li id="news"><a href="market"><span class="a-btn-symbol"><img src="images/market.png" style="width:27px; height:27px;"></span>Market</a></li>
                <li id="about"><a href="report"><span class="a-btn-symbol"><img src="images/report.png" style="width:27px; height:27px;"></span>Report</a></li>
                <li id="services"><a href="tools"><span class="a-btn-symbol"><img src="images/tools.png" style="width:27px; height:27px;"></span>Tools</a></li>
                <li id="contact"><a href="analytics"><span class="a-btn-symbol"><img src="images/analytics.png" style="width:27px; height:27px;"></span>Analytics</a></li>
                <li id="contact"><a href="links"><span class="a-btn-symbol">K</span>Links</a></li>
                <li id="contact"><a href="help"><span class="a-btn-symbol"><img src="images/help.png" style="width:27px; height:27px;"></span>Help</a></li>
            </ul>
              </nav>
              </div>
                <div class="clr"></div>
                
                <div class="middle-header">
                <nav id="main-nav">
                    <ul>
                    <li>
                    <a title="Calculator" class="href" target="_self" onClick="window.open('calculator','targetWindow','toolbar=no,location=no,status=no,menubar=no,scrollbars=yes,resizable=yes,top=300,width=1200,height=200')"><img src="images/calculator.png" height="25" width="25" style="margin-top:5px;"></a>
                    <span></span>                    </li>
                    <li>
                    <a title="Custom Portfolio" href="#"><img src="images/custom-portfolio.png" height="25" width="25" style="margin-top:5px;"></a>
                    <span></span>                    </li>
                    <li>
                    <a title="Predefined Portfolio" href="#"><img src="images/predefined-portfolio.png" height="25" width="25" style="margin-top:5px;"></a>
                    <span></span>                    </li>
                    <li>
                    <a title="Refresh" href="#"><img src="images/refresh.png" height="25" width="25" style="margin-top:7px;"></a>
                    <span></span>                    </li>
                    <li>
                    <a title="Client Facility" href="#" onclick="showmenu()" id="show"><img src="images/client-facility.png" height="25" width="25" style="margin-top:5px;"></a>
                    <span></span>                    </li>
                    <li>
                    <a title="Keyboard Shortcut" href="#" onmouseover="showmenu()" id="show1"><img src="images/keyboard-shortcut.png" height="25" width="25" style="margin-top:7px;"></a>
                    <span></span>                    </li>
                   
                  </ul>
                 </nav>
                </div>
        
        <div id="mm" class="easyui-menu" style="width:200px;">
		<div >
			<a title="Change Password" class="href" target="_self"  onclick="BuySell1('buy');" href="javascript:void(0)" style="color: #000">
			Change Password
			</a>
		</div>
	
		<div>
			<a title="Change Transaction Password" class="href" target="_self" href="javascript:void(0);" onclick="BuySell1('sell')" style="color: #000">
			Change Transaction Password
			</a>
		</div>
        </div>
                
        <div id="ks" class="easyui-menu" style="width:220px;">
		<div>
		<a style="color:black">
			Buy&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;
			&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;Page Up
		</a>
		</div>
		<div>
		<a style="color:black">Sell &nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;
		&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;
		Page Down</a>
		</div>
		<div>
		<a style="color:black">Calculator &nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;
		&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;
		  Alt+c</a>
		  
		</div>
		
        <div>
		<a style="color:black">Lots Increase &nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;   &#8593;</a>
		</div>
		<div>
		<a style="color:black">Lots Decrease &nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;   &#8595;</a>
		</div>
                </div>
                <div style="width:100%; float:left;">
                	<div style="border-style:groove; border-width:1px;font-family:helvetica; font-size:13px;" width="80%">
<div ><select><option>NMCEX</option>

</select>
<select>
<option>-Select-</option><option>FUTURE</option>

</select>
<select id="prdid" name="prdid">
				 <option>-Select-</option>
				 <option value="ALUMINIUM_L">ALUMINIUM L</option>
                 <option value="ALUMINIUM_S">ALUMINIUM S</option>
                 <option value="BRCRUDE_OIL">BRCRUDE OIL</option>
                 <option value="COPPER_L">COPPER L</option>
                 <option value="COPPER_S">COPPER S</option>
                 <option value="CRUDE_OIL">CRUDE OIL</option>
                 <option value="GOLD_L">GOLD L</option>
                 <option value="GOLD_S">GOLD S</option>
                 <option value="LEAD_L">LEAD L</option>
                 <option value="LEAD_S">LEAD S</option>
                 <option value="NATURAL_GAS">NATURAL GAS</option>
                 <option value="SILVER_L">SILVER L</option>
                 <option value="SILVER_S">SILVER S</option>
                 <option value="ZINC_L">ZINC L</option>
                 <option value="ZINC_S">ZINC S</option>
                 <option value="NICKEL_L">NICKEL L</option>
                 <option value="NICKEL_S">NICKEL S</option></select>
<select id="timeid" name="timeid" onchange="callFunction();">
<option>-Select-</option>

<option value="30Aug2014" onclick="">30Aug2014</option>
<option value="30Sep2014" onclick="">30Sep2014</option>
</select>

<input type="text" value="Profit / Loss" size="15" disabled style="margin-left:20%; background:#006633; color:#FFFFFF;text-align: center;" id="profit" />
</div>
</div>
                </div>
          </div>

<!--Main Container--------------------------------------------------------------------------------------->          
<div  id="container" style="height:345px; overflow:scroll;" ><!--<img src="img/ncmx-logo2.png" align="middle" width="800" height="300" style=" margin-left:200px; margin-top:20px;"/>                                   class="easyui-datagrid"-->

<table id="tblDataGrid" class='list' cellspacing="0" cellpadding="0" border="0" width="300"  style="width:100%; border:thin groove;" singleSelect="true" iconCls="icon-save" url="data/datagrid_data.json" >
     <thead style="background:#CCCCCC;">
        <tr>
           <th>Symbol</th>
             <th id="insname"  >Instr. Id</th>	
		  <th>Series/Expiry</th>
		  <th>Bid Qty</th>
		  <th>Bid Rate</th>
		  <th>Ask Rate</th>
		  <th>Ask Qty</th>
		  <th>Net Change</th>
		  <th>Open</th>
		  <th>High</th>
		  <th>Low</th>
		  <th>Prev Close</th>
		  <th>LTP</th>
		  <th>% Change</th>
		  <th>Avg. Trade Price</th>
		  <th>DPR</th>
		  <th>Vol.in(Lacs)</th>				
		  <th>Trend</th>				
		  <th>Life Time High</th>
		  <th>Life Time Low</th>
        </tr>
    </thead>
     <tbody style="height:100%; overflow:scroll;"   width="100%" border="0" class="datagrid-btable" id="Heading">

    </tbody>
</table>
<script language="javascript">

var table = document.getElementsByTagName("table")[0];
var tbody = table.getElementsByTagName("tbody")[0];
var row = table.getElementsByTagName("tr")[0];

tbody.onclick = function (e) {
    e = e || window.event;
    var data = [];
    var target = e.srcElement || e.target;
    while (target && target.nodeName !== "TR") {
        target = target.parentNode;
		
    }
    if (target) {
	
        var cells = target.getElementsByTagName("td");
        for (var i = 0; i < cells.length; i++) {
           data.push(cells[i].innerHTML);
           var j=i+1;
		   var k=i+21;
		   if(j==1){
			   document.getElementById('symbol').value=(cells[i].innerHTML);
			   }
			    if(j==2){
			   document.getElementById('insname').value=(cells[i].innerHTML);
			   }
			    if(j==3){
					   document.getElementById('expdate').value=(cells[i].innerHTML);
					   }
			    if(j==5){
			   document.getElementById('price').value=(cells[i].innerHTML);
			   }
			    if(k==21){
			    	document.getElementById('ssymbol').value=(cells[i].innerHTML);
			    }
			    if(k==22){
			    	document.getElementById('sinsname').value=(cells[i].innerHTML);
			    }
			    if(k==23){
			    	document.getElementById('sexpdate').value=(cells[i].innerHTML);
			    }
			
			    if(k==26){
			    	document.getElementById('sprice').value=(cells[i].innerHTML);
			    }
		   
        }
    }
 
};

</script>

        	<script>
       	var id,productid;
       	function callFunction(){
       		id = document.getElementById('prdid').value;
       		productid = document.getElementById('timeid').value;
       		var select = document.getElementById("timeid");
       		$('#timeid option[value!="0"]').remove();
       		var option = document.createElement("option");
       			option.value ="";
               option.textContent ="-Select-";
               select.appendChild(option);
            var option1 = document.createElement("option");
       	     	option1.value ="30Aug2014";
       	        option1.textContent ="30Aug2014";
       	        select.appendChild(option1);
       	     var option2 = document.createElement("option");
       		 	   option2.value ="30Sep2014";
       	           option2.textContent ="30Sep2014";
       	           select.appendChild(option2);
       	
       }
       	/* 
       		var socket = new SockJS("/ncmxtradeX/hs");
       		var stompClient = Stomp.over(socket);

       		function renderQuote(frame) {
       			var Headings = JSON.parse(frame.body);
       			for ( var i in Headings) {
       				var Heading = Headings[i];
       			var rows=document.all("Heading").rows.length;
               	var rowid = 'row'+rows;
               	updateRow(Heading);
       			
       			if(Heading['symbol'] == id && Heading['contentId'] == productid){
       				var a=findRow(id,productid,Heading);
       				if(a==0){
       				$('#Heading').append(
       						$('<tr id='+rowid+'>').append(
       								$('<td>').html(Heading.symbol),
    								$('<td>').html(Heading.instId),
    								$('<td>').html(Heading.contentId),
    								$('<td>').html(Heading.ask_Qty),
    								$('<td>').html(Heading.bid_Rate),
    								$('<td>').html(Heading.ask_Rate),
    								$('<td>').html(Heading.bid_Qty),
    								$('<td>').html(Heading.netChange),
    								$('<td>').html(Heading.open),
    								$('<td>').html(Heading.high),
    								$('<td>').html(Heading.low),
    								$('<td>').html(Heading.prev_Close),
    								$('<td>').html(Heading.ltp),
    								$('<td>').html(Heading.perChange),
    								$('<td>').html(Heading.atp),
    								$('<td>').html(Heading.dpr),
    								$('<td>').html(Heading.voll),
    								$('<td>').html(Heading.trend),
    								$('<td>').html(Heading.lth),
    								$('<td>').html(Heading.ltl)
       							)	
       						);
       				}
       			}
       			}
       		}
       		
       		var connectCallback = function() {
       			stompClient.subscribe('/topic/Heading', renderQuote);
       		};

       		var errorCallback = function(error) {
       			alert(error.headers.message);
       		};

       		stompClient.connect("guest", "guest", connectCallback, errorCallback);

       		function findRow(id,productId,Heading){
       			var a=0;
       			
       			var table = document.getElementById("Heading");
       			for (var i = 0, row; row = table.rows[i]; i++) {
       					if(row.cells[0].innerHTML==id && row.cells[2].innerHTML==productId){
       					 row.cells[0].innerHTML=Heading.symbol;
						 	row.cells[1].innerHTML=Heading.instId;
							row.cells[2].innerHTML=Heading.contentId;
							row.cells[3].innerHTML=Heading.ask_Qty;
							row.cells[4].innerHTML=Heading.bid_Rate;
							row.cells[5].innerHTML=Heading.ask_Rate;
							row.cells[6].innerHTML=Heading.bid_Qty;
							row.cells[7].innerHTML=Heading.netChange;
							row.cells[8].innerHTML=Heading.open;
							row.cells[9].innerHTML=Heading.high;
							row.cells[10].innerHTML=Heading.low;
							row.cells[11].innerHTML=Heading.prev_Close;
							row.cells[12].innerHTML=Heading.ltp;
							row.cells[13].innerHTML=Heading.perChange;
							row.cells[14].innerHTML=Heading.atp;
							row.cells[15].innerHTML=Heading.dpr;
							row.cells[16].innerHTML=Heading.voll;
							row.cells[17].innerHTML=Heading.trend;
							row.cells[18].innerHTML=Heading.lth;
							row.cells[19].innerHTML=Heading.ltl; 
       						a=1;
       						break;
       					}			     
       			}
       			return a;
       		}
       		
       		function updateRow(Heading){
       			var table = document.getElementById("Heading");
       			for (var i = 0, row; row = table.rows[i]; i++) {
       			  if(row.cells[0].innerHTML==Heading.symbol && row.cells[2].innerHTML==Heading.contentId){
       				 row.cells[0].innerHTML=Heading.symbol;
					 	row.cells[1].innerHTML=Heading.instId;
						row.cells[2].innerHTML=Heading.contentId;
						row.cells[3].innerHTML=Heading.ask_Qty;
						row.cells[4].innerHTML=Heading.bid_Rate;
						row.cells[5].innerHTML=Heading.ask_Rate;
						row.cells[6].innerHTML=Heading.bid_Qty;
						row.cells[7].innerHTML=Heading.netChange;
						row.cells[8].innerHTML=Heading.open;
						row.cells[9].innerHTML=Heading.high;
						row.cells[10].innerHTML=Heading.low;
						row.cells[11].innerHTML=Heading.prev_Close;
						row.cells[12].innerHTML=Heading.ltp;
						row.cells[13].innerHTML=Heading.perChange;
						row.cells[14].innerHTML=Heading.atp;
						row.cells[15].innerHTML=Heading.dpr;
						row.cells[16].innerHTML=Heading.voll;
						row.cells[17].innerHTML=Heading.trend;
						row.cells[18].innerHTML=Heading.lth;
						row.cells[19].innerHTML=Heading.ltl; 
       			  } 
       			}	
       		}
       		 */
       	</script> 
                    

</div>

<!--FOOTER---------------------------------------------------------------------------------------->          
  <%@include file="footer.jsp" %>
</body>
</html>